package app.service.loader
{
	
	import app.service.event.URLLoaderServiceEvent;

	import com.gaiaframework.debug.GaiaDebug;
	
	import flash.events.*;
	import flash.net.*;

	
	public class ConfigURLLoaderService extends BaseURLLoaderService
	{

		
		override protected function completeHandler(event:Event):void {
			var loader:URLLoader = URLLoader(event.target);
			//GaiaDebug.log("completeHandler: " + loader.data);
			
			appModel.configDATA = new XML(loader.data);
			dispatch(new URLLoaderServiceEvent(URLLoaderServiceEvent.CONFIG_DATA_LOADED));
			
			//var vars:URLVariables = new URLVariables(loader.data);
			//GaiaDebug.log("The answer is " + vars.answer);
			super.completeHandler(event);
		}
		
	}
}